//
//  HHAlertSheetController.h
//  AliyunOSSiOS
//
//  Created by chasel. c on 2022/10/27.
//  自定义sheet弹框

#import <UIKit/UIKit.h>

NS_ASSUME_NONNULL_BEGIN

@interface HHAlertSheetController : UIViewController

/// 内容view
@property (nonatomic, strong) UIView *contentView;
/// 数据源支持<NSString,NSAttributedString>
@property (nonatomic, strong) NSArray *dataArr;
/// 禁止交互某一行
@property (nonatomic, assign) NSInteger enableAtIndex;
/// 选择回调
@property (nonatomic, copy, nullable) void (^ selectedBlock)(NSInteger index);


/// 快速显示alertSheet
/// @param title 标题
/// @param dataList 数据
/// @param completion 回调
+ (HHAlertSheetController *)shoWithTitle:(nullable NSString *)title list:(NSArray *)dataList completion:(void (^_Nullable)(NSInteger index))completion;


/// 快速显示alertSheet
/// @param title 标题
/// @param dataList 数据
/// @param cancelTitle 取消标题
/// @param completion completion description
+ (HHAlertSheetController *)shoWithTitle:(nullable NSString *)title list:(NSArray *)dataList cancelTitle:(nullable NSString *)cancelTitle completion:(void (^_Nullable)(NSInteger index))completion;

+ (HHAlertSheetController *)shoWithTitle:(nullable NSString *)title list:(NSArray *)dataList itemHeight:(CGFloat )height cancelTitle:(nullable NSString *)cancelTitle completion:(void (^_Nullable)(NSInteger index))completion;


/// 快速显示alertSheet
/// @param attributedTitle 富文本标题
/// @param dataList 数据
/// @param cancelTitle 取消标题
/// @param completion completion descriptio
+ (HHAlertSheetController *)showAttributedTitle:(nullable NSAttributedString *)attributedTitle list:(NSArray *)dataList cancelTitle:(nullable NSString *)cancelTitle completion:(void (^_Nullable)(NSInteger index))completion;

@end

NS_ASSUME_NONNULL_END
